home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
dskut
/
diet145f.zip
/
DIET145F.DOC
< prev
next >
Wrap
Text File
|
1992-10-25
|
31KB
|
786 lines
------------------------------------------------------------
DIET.DOC for DIET.EXE v.1.45F
------ by Teddy Matsumoto ---------
(DOCFILE: October 1992)
------------------------------------------------------------
1.0. OVERVIEW.
1.1. DIET.EXE reduces the disk-storage space needed by ex-
ecutable and data files WITHOUT giving up immediate access to
such files. DIET is a Freeware Program.
(a) When DIET compresses an EXECUTABLE file (.EXE or .COM),
it adds a header that automatically expands the file when
it is executed.
(b) On average, DIET reduces the size of .EXE & .COM files
by 40%.
(c) Self-expansion of DIETed .EXE & .COM files is so fast
that it is difficult to measure the change in the speed
of file execution. You certainly won't notice any
change.
(d) DIET's self-expansion of .EXE and .COM files is similar
to PKLITE or LZEXE, except that DIET also lets you com-
press overlay files -- something that PKLITE and LZEXE
cannot do.
1.2. What makes DIET really unique is its ability to compress
DATA Files and to automatically expand them when you call them
into an Word Processor or Editor to read or change them.
(a) To use that feature, you must load DIET so that it is
resident in memory (i.e., Terminate and Stay Resident, or
TSR).
(b) DIET reduces the size of an average DATA File by 2/3rd.
(c) DIET's automatic expansion of Data Files adds a little
time (on a 386SX-16 system, about 3 sec. compared to
loading a 100k byte unDIETed text file into an editor).
But that is a small price for the benefit of being able
to keep infrequently-used Data Files on your Hard Disk,
instead of having to store them on floppies. And you can
optionally set up DIET so that it will automatically
recompress Data Files when you exit your Editor.
(d) Many -- but not all -- application programs can use
DIETed DATA files. For example, QUATTRO can use DIETed
???.WQ1 files; dBASE cannot use DIETed ???.DBF files.
You'll have to experiment.
This document is the USER'S GUIDE for DIET v.1.45F. To learn
about DIET's internals and changes from version to version, see
DIETAPI.DOC and DIETTECH.DOC Those much more technical documents
are of no importance to the average USER of DIET, but are avail-
able for programmers and the curious.
2.0. A QUICK INTRODUCTION TO WHAT DIET CAN DO.
2.1. OVERVIEW. For our discussion, it is useful to classify
DOS files into three general types:
∙ EXECUTABLE, i.e., ???.EXE and ???.COM
∙ DEVICE DRIVERS, e.g., ???.SYS or ???.DRV
∙ DATA, e.g. ???.DOC, ???.TXT, ???.WQ1, etc.
2.1.1. DIET compresses EXECUTABLES and DRIVERS so that from the
user's perspective they perform the same as if they were not
compressed. That means you can execute them directly, or load
them from your CONFIG.SYS. We call this feature selF-eXtracting,
or SFX.
2.1.2. You can use DIET to compress DATA-type files, but they
are NOT self-extracting. To use DIETed DATA files, you must
either decompress manually or load DIET as a TSR so that they are
decompressed automatically when your application program loads
them.
2.1.3. To compress your files on the current directory, simply
type:
DIET filename,
or use wildcards, e.g.,
DIET *.*
When you use DIET without any options, EXECUTABLES and DRIVERS
are compressed as SFX, and all other files as non-SFX types
files.
2.1.4. To know whether or not a file has been compressed by
DIET, type:
DIET -l
That will display all files in the current directory, with com-
pressed files in reverse color.
2.1.5. To restore non-SFX compressed files to their uncompressed
status, type
DIET -r filename.ext, or DIET -r *.*
2.1.6. The simplest -- but not best -- use of DIET would be to
execute both of the following commands in a directory:
DIET *.*
followed by
DIET -r *.*
That would leave you with EXECUTABLES and DRIVERS in SFX mode,
and all other files (the DATA-type files) uncompressed.
To restore all DIETed files, including compressed executable or
driver files, type
DIET -ra filename.ext or DIET -ra *.*
2.2. DIET in TSR Mode.
We assume you're displaying DIET.DOC on your console, using
the DOS MORE command, Vernon Buerg's LIST.COM, or your favorite
Editor. Try the following:
(a) Return to DOS.
(b) Execute:
DIET DIET.DOC
That will compress this file. If you now try view the
file with MORE, or read it with LIST or your favorite
editor, you'll get garbage.
(c) Now Execute:
DIET -Z
That will load DIET in the TSR mode and allows you to
display DIET.DOC with MORE, LIST, or your Editor. Try
it.
(d) Remove the DIET TSR by executing:
DIET -ZR
(e) Finally, restore (i.e., decompress) DIET.DOC by
executing:
DIET -R DIET.DOC
3.0. USING DIET's OPTIONS
3.1. The basic DIET command structure is:
DIET [options] [file-names]
{wild-cards are OK in filenames}
Options require a prefix. You may use either "-" or "/" as the
option-prefix. Multiple options must be separated by spaces,
e.g.
DIET -z -p -td:\tmp
3.2. Options fall into two general categories:
(a) BASIC options that specify fundamental DIET functions,
and
(b) AUXILIARY Options that modify the operation of a BASIC
option.
3.3. The following table summarizes the BASIC and AUXILIARY
Options:
------------------------------------------------------------------
BASIC Function of the AUXILIARY Options that can
Option BASIC Option Be used with the BASIC option
------------------------------------------------------------------
DIET w/o Compress the named -X,-XC,-G,-D,-B,-K,-I,-A
option files -E, -Oxxxxx.
------------------------------------------------------------------
-R,-RA Decompress named files -Oxxxxx.
------------------------------------------------------------------
-Cxxxxx Copy without -R,-RA,-A
decompress/recompress
------------------------------------------------------------------
-L Identify compressed files.
-H Check integrity of compressed file, using CRC
------------------------------------------------------------------
-! Check DIET's own validity
-? Display Help Screen.
-$ Compress later (see -N)
------------------------------------------------------------------
-Z[n] Load DIET as a TSR. Value -P,-W,-N,-M
of [n] defines where in -S,-Txxxxxx
memory DIET is loaded.
------------------------------------------------------------------
-ZD Disable TSR DIET (also DIET OFF)
-ZA Activate TSR DIET (also DIET ON)
-ZR Remove TSR DIET from memory.
------------------------------------------------------------------
3.4. The following table summarizes what the file-related
AUXILIARY options do. Not included in the table are the
AUXILIARY options related to TSR-user of DIET -- they are dis-
cussed at xx, below. For more details on options, see the full
discussion of options at xx, below.
SUMMARY of what FILE-RELATED OPTIONS do.
-X Compress as SFX type.
-XC Force compression of a .COM file as a real SFX .COM file